package com.jrx.anytxn.transaction.dto.loan;

import com.jrx.anytxn.transaction.dto.common.CommonReq;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.math.BigDecimal;

/**
 * 同步API放款失败请求类型
 *
 * @author liuyang
 * @date 2021-04-03
 */
public class SyncLoanFailInfoReq extends CommonReq {

    @ApiModelProperty(value = "外部合同号")
    @NotEmpty(message = "外部合同号不允许空")
    @Size(max = 60, message = "订单编号不能超过60位")
    private String contractNumber;

    @ApiModelProperty(value = "客户姓名")
    @NotEmpty(message = "客户姓名不允许空")
    @Size(max = 60, message = "客户姓名不能超过60位")
    private String customerName;

    @ApiModelProperty(value = "放款时间")
    @NotEmpty(message = "放款时间不允许空")
    @Size(max = 20, message = "放款时间不能超过20位")
    private String loanDate;

    @ApiModelProperty(value = "贷款金额")
    @NotNull(message = "贷款金额不允许空")
    private BigDecimal loanAmount;

    @ApiModelProperty(value = "执行利率")
    @NotNull(message = "执行利率不允许空")
    private BigDecimal actualRate;

    @ApiModelProperty(value = "放款结果")
    @NotEmpty(message = "放款结果不允许空")
    @Size(max = 1, message = "放款结果不能超过1位")
    private String status;

    @ApiModelProperty(value = "异常代码")
    @Size(max = 200, message = "异常代码不能超过200位")
    private String errorCode;

    @ApiModelProperty(value = "异常原因")
    @Size(max = 400, message = "异常原因不能超过400位")
    private String errorMsg;

    @ApiModelProperty(value = "产品id")
    @NotEmpty(message = "产品id不允许空")
    @Size(max = 32, message = "产品id不能超过32位")
    private String productId;

    public String getContractNumber() {
        return contractNumber;
    }

    public void setContractNumber(String contractNumber) {
        this.contractNumber = contractNumber;
    }

    public String getCustomerName() {
        return customerName;
    }

    public void setCustomerName(String customerName) {
        this.customerName = customerName;
    }

    public String getLoanDate() {
        return loanDate;
    }

    public void setLoanDate(String loanDate) {
        this.loanDate = loanDate;
    }

    public BigDecimal getLoanAmount() {
        return loanAmount;
    }

    public void setLoanAmount(BigDecimal loanAmount) {
        this.loanAmount = loanAmount;
    }

    public BigDecimal getActualRate() {
        return actualRate;
    }

    public void setActualRate(BigDecimal actualRate) {
        this.actualRate = actualRate;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getErrorCode() {
        return errorCode;
    }

    public void setErrorCode(String errorCode) {
        this.errorCode = errorCode;
    }

    public String getErrorMsg() {
        return errorMsg;
    }

    public void setErrorMsg(String errorMsg) {
        this.errorMsg = errorMsg;
    }

    public String getProductId() {
        return productId;
    }

    public void setProductId(String productId) {
        this.productId = productId;
    }
}
